'use strict';
import React, { useContext } from 'react'
import { Navigate } from "react-router-dom";
import HttpContext from "../../server/httpContext";


const Index = () => {
  let context = useContext(HttpContext);
  console.log(context, "context-user");

  // 在这里做逻辑判断然后重定向跳到登录页面
  if (true) { }
  context.staticContext.action = "REPLACE";
  context.staticContext.url = "/";
  // TODO v6 删除了Redirect 使用Navigate重定向
  return <Navigate to="/" />
};

export default Index